package org.example.service.impl;

import org.example.service.DynamicService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.concurrent.ThreadPoolExecutor;

/**
 * @author cgwb6
 * @description 动态线程池接口
 * @date 2025/9/25 17:02
 */
@Service
public class DynamicServiceImpl implements DynamicService {

    @Resource
    private ThreadPoolExecutor dtpExecutor1;

    public void exec() {
        dtpExecutor1.execute(() -> System.out.println("test"));
    }

}